<!DOCTYPE html>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
	<title>{{ title }}</title>
</head>
<body>
	<table id="table">
		{%- if caption %}
		<caption>{{ caption }}</caption>
		{%- endif %}
	</table>

	<script src="js/jquery.min.js" type="text/javascript"></script>
	<script src="js/jquery.dataTables.min.js" type="text/javascript"></script>
	{%- if virtual_scroll %}
	<script src="js/dataTables.scroller.min.js" type="text/javascript"></script>
	{%- endif %}
	{%- if enable_export %}
	<script src="js/dataTables.buttons.min.js" type="text/javascript"></script>
	<script src="js/buttons.html5.min.js" type="text/javascript"></script>
	<script src="js/buttons.print.min.js" type="text/javascript"></script>
	{%- endif %}
	<script>
		$(document).ready(function() {
			$("#table").DataTable({{ datatable_options | safe }});
		});
	</script>
	<style>
		body,
		html {
			margin: 0;
			font-family: "Lucida Sans Unicode", "Lucida Grande", Sans-Serif;
		}
		table.dataTable {
			width: 100%;
			margin: 0 auto;
			clear: both;
			border-collapse: separate;
			border-spacing: 0;
		}

		table.dataTable thead th,
		table.dataTable tfoot th {
			font-weight: bold;
		}

		table.dataTable thead th,
		table.dataTable thead td {
			padding: 10px 18px;
			border-bottom: 1px solid #111;
		}

		table.dataTable thead th:active,
		table.dataTable thead td:active {
			outline: none;
		}

		table.dataTable tfoot th,
		table.dataTable tfoot td {
			padding: 10px 18px 6px 18px;
			border-top: 1px solid #111;
		}

		table.dataTable tbody th,
		table.dataTable tbody td {
			padding: 8px 10px;
		}

		#table_wrapper {
			margin: 20px 40px;
		}

		table tr th,
		table tr td {
			text-align: left;
			white-space: nowrap;
		}

		#table_wrapper .dataTables_length,
		#table_wrapper .dataTables_filter {
			margin-bottom: 20px;
			font-size: 10px;
			text-transform: uppercase;
			float: right;
   		margin-left: 20px;
		}

		#table_wrapper .dataTables_length label,
		#table_wrapper .dataTables_filter label,
		#table_wrapper .dataTables_paginate a,
		#table_wrapper .dataTables_info {
			color: #039 !important;
		}

		#table_wrapper .dataTables_filter input {
			margin: 0 3px;
		}

		#table_wrapper .dataTables_paginate a,
		#table_wrapper .dataTables_info {
			font-size: 10px;
			text-transform: uppercase;
		}

		#table_wrapper .dataTables_paginate {
			float: right;
		}

		#table_wrapper .dataTables_paginate,
		#table_wrapper .dataTables_info {
			display: inline-block;
			margin-top: 10px;
		}

		#table_wrapper .dataTables_paginate a {
			padding: 3px 6px;
			margin: 0 5px;
			cursor: pointer;
		}

		#table_wrapper .dataTables_paginate a.current {
			color: #fff !important;
			background: #039;
		}

		#table_wrapper table {
			font-size: 12px;
			background: #fff;
			border-collapse: collapse;
			text-align: left;
			width: 100%;
		}

		#table_wrapper table caption {
			font-size: 20px;
			color: #039;
			text-align: left;
			margin-bottom: 10px;
		}

		#table_wrapper table th {
			font-size: 14px;
			font-weight: normal;
			color: #039;
			padding: 10px 8px;
			border-bottom: 2px solid #6678b1;
			position: relative;
		}

		#table_wrapper .dataTables_scrollHead th.sorting,
		#table_wrapper .dataTables_scrollHead th.sorting_asc,
		#table_wrapper .dataTables_scrollHead th.sorting_desc {
			position: relative;
			cursor: pointer;
		}

		#table_wrapper .dataTables_scrollHead th.sorting:before,
		#table_wrapper .dataTables_scrollHead th.sorting_asc:before,
		#table_wrapper .dataTables_scrollHead th.sorting:after,
		#table_wrapper .dataTables_scrollHead th.sorting_desc:after {
			border: 4px solid transparent;
			position: absolute;
			display: block;
			content: "";
			height: 0;
			right: 8px;
			top: 50%;
			width: 0;
			opacity: 0.4;
		}

		#table_wrapper .dataTables_scrollHead th.sorting:before,
		#table_wrapper .dataTables_scrollHead th.sorting_asc:before {
			border-bottom-color: #669;
			margin-top: -9px;
		}

		#table_wrapper .dataTables_scrollHead th.sorting:after,
		#table_wrapper .dataTables_scrollHead th.sorting_desc:after {
			border-top-color: #669;
			margin-top: 1px;
		}

		#table_wrapper table td {
			border-bottom: 1px solid #ccc;
			color: #669;
			padding: 6px 8px;
		}

		#table_wrapper table tbody tr:hover td {
			color: #009;
		}

		.dt-buttons {
			display: inline-block;
		}

		.dt-button {
			color: #FFFFFF;
			background: #039;
			margin-right: 10px;
			padding: 6px 12px;
			cursor: pointer;
			-webkit-transition: all 60ms ease-in-out;
			transition: all 60ms ease-in-out;
			text-align: center;
			white-space: nowrap;
			text-decoration: none !important;
			text-transform: none;
			text-transform: capitalize;
			border: 0 none;
			border-radius: 2px;
			font-size: 11px;
			line-height: 1.3;
			text-transform: uppercase;
		}

		.dt-button-info {
			padding: 50px;
			color: #039;
			text-align: center;
			position: fixed;
			top: 0;
			left: 0;
			right: 0;
			bottom: 0;
			background: rgba(255, 255, 255, 0.7)
		}

		.dt-button-info h2 {
			display: none;
		}
</body>
</html>
